<div class="span10" id="_content" style="background: #fff;margin-left: 2px">
<table width="100%" style="margin: 0;padding: 0;">
    <tr>
        <td class="hzbar"></td>
        <td style="padding: 10px 15px;"><?php echo $this->session->flashdata('_message'); ?>
<!-- Modal Form -->
<div style="margin-bottom: 15px;"></div>

<?php
if(!$this->uri->segment(6)){
if(!empty($users)){
?>
    <table class="table table-striped table-bordered table-condensed">
        <?php 
            foreach($users as $use):
            $profile = $this->_global->_unserialize($use->profile_detail);
        ?>
        <tr>
            <td><?php echo  $use->id ?></td>
            <td><?php echo  $profile['hoten'] ?></td>
            <td><?php echo  mdate('%d/%m/%Y',$use->created) ?></td>
             <td>
                <?php echo anchor('administrator/customer/customer/index/view/'.$use->id,'View', 'class="btn action"') ?>
            </td>
            
            
        </tr>
        <?php endforeach; ?>
    </table>
<?php
}else{
    echo '<div class="alert alert-info"><h4 class="alert-heading">Thông báo!</h4>Chưa có user nào...</div>';
}}
?>
<?php 
    if($this->uri->segment(6)){
    ?>
    <div><script src="http://cdn.printfriendly.com/printfriendly.js" type="text/javascript"></script><a href="http://www.printfriendly.com" style=" color:#6D9F00; text-decoration:none;" class="printfriendly" onclick="window.print(); return false;" title="Printer Friendly and PDF"><img style="border:none;" src="http://cdn.printfriendly.com/pf_button_sq_gry_m.png" alt="Print Friendly and PDF"/></a></div>
    <table class="table table-striped table-bordered table-condensed">
      <?php  $user = $this->_global->_unserialize($user->profile_detail);
      
?>
    <tr>
        <td width="20%">Họ tên</td>
        <td><?php echo $user['hoten'] ?></td>
    </tr>
    <tr>
        <td width="20%">Giới tính</td>
        <td><?php echo $user['gioitinh'] ?></td>
    </tr>
    <tr>
        <td width="20%">Tuổi</td>
        <td><?php echo $user['tuoi'] ?></td>
    </tr>
    <tr>
        <td width="20%">Địa chỉ</td>
        <td><?php echo $user['address'] ?></td>
    </tr>
    <tr>
        <td width="20%">Email</td>
        <td><?php echo $user['email'] ?></td>
    </tr>
    <tr>
        <td width="20%">Mục tiêu tập luyện</td>
        <td><?php echo $user['target'] ?> :<?php echo implode(',',$user['tagets']) ?> </td>
    </tr>
    <tr>
        <td width="20%">Mục tiêu khác</td>
        <td><?php echo $user['other'] ?></td>
    </tr>
    <tr>
        <td width="20%">Bệnh lý</td>
        <td><?php echo implode(',',$user['vande']) ?></td>
    </tr>
    <tr>
        <td width="20%">Bệnh lý khác</td>
        <td><?php echo $user['benhkhac'] ?></td>
    </tr>
    <tr>
        <td width="20%">Tập Gym</td>
        <td><?php echo $user['gym'] ?>:<?php echo $user['chedo'] ?></td>
    </tr>
    <tr>
        <td width="20%">Chiều cao</td>
        <td><?php echo $user['height'] ?></td>
    </tr>
    <tr>
        <td width="20%">Cân nặng</td>
        <td><?php echo $user['weight'] ?></td>
    </tr>
    <tr>
        <td width="20%">BMR</td>
        <td><?php echo $user['bmr'] ?></td>
    </tr>
    <tr>
        <td width="20%">BMI</td>
        <td><?php echo $user['bmi'] ?></td>
    </tr>
    <tr>
        <td width="20%">Tỉ lệ % mỡ</td>
        <td><?php echo $user['tilemo'] ?></td>
    </tr>
    <tr>
        <td width="20%">Tỉ lệ eo hông</td>
        <td><?php echo $user['eohong'] ?></td>
    </tr>
    <?php
}?>
</table>

</td></tr>


</table>
</div>